DEF_PROJECT=../../..
include $(DEF_PROJECT)/scripts/main.mk
name=libusb
version=1.0.9
prefix=/usr
destdir=$(DIR_SYSROOT)
extdeps=eglibc-tools gcc-tools binutils-tools linux-header-tools

DL_SERV=http
DL_HOST=nchc.dl.sourceforge.net
DL_PATH=project/$(name)/$(name)-1.0/$(name)-$(version)
DL_SUFFIX=tar.bz2

cflags+=--host=$(CC_TARGET)
cflags+=--build=$(CC_HOST)

post-build:
	$(MAKE) -C $(if $(build),$(build),$(source)) $(iflags)
	sed -i 's@prefix=.*@prefix=$(destdir)/$(prefix)@' $(destdir)/$(prefix)/lib/pkgconfig/libusb-1.0.pc
